#include<iostream>
using namespace std;
int main(){
	unsigned int a;
	unsigned int temp1,temp2;
	cin>>a;
	temp1=a>>16;
	temp2=a<<16;
	cout<<temp1+temp2; 
} 
